package com.xx.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.xx.entity.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

/**
 * <p>
 * 用户权限表
 * </p>
 *
 * @author myx
 * @since 2024-12-23
 */
@Getter
@Setter
@TableName("sys_permission")
@Schema(name = "Permission", description = "用户权限表")
public class Permission extends BaseEntity {

    @Schema(description = "父编号")
    @TableField("p_id")
    private String pId;

    @Schema(description = "父编号列表")
    @TableField("p_ids")
    private String pIds;

    @Schema(description = "权限字符串 xxx:add;xxx:view")
    @TableField("resource")
    private String resource;

    @Schema(description = "资源类型 【menu|button】")
    @TableField("resource_type")
    private String resourceType;

    @Schema(description = "资源路径 /userinfo/list")
    @TableField("url")
    private String url;

    @Schema(description = "权限名称")
    @TableField("name")
    private String name;
}
